package com.packenius.library.xspdf;

import java.util.HashMap;
import java.util.Map;

/**
 * Alternative font encoding - only for SYMBOL font with 'apple' character
 * usage.
 * 
 * @author Christian Packenius, 2013.
 */
class XST1AltFontEncoding4 extends XSAlternativeFontEncoding {
  /**
   * Maps an Utf-8 (Unicode?) code (0..65535) to the byte in this font encoding.
   */
  static final Map<Character, Character> altFontEncoding4 = new HashMap<Character, Character>();

  private static final String altFontEnc4Diffs = "255 /apple";

  static {
    altFontEncoding4.put('\uf8ff', (char) 255);
  }

  /**
   * @see com.packenius.library.xspdf.XSAlternativeFontEncoding#getPdfDifferencesListContent()
   */
  @Override
  public String getPdfDifferencesListContent() {
    return altFontEnc4Diffs;
  }

  /**
   * @see com.packenius.library.xspdf.XSAlternativeFontEncoding#getID()
   */
  @Override
  public String getID() {
    return "4";
  }

  /**
   * @see com.packenius.library.xspdf.XSAlternativeFontEncoding#getCharacterEncodingMap()
   */
  @Override
  public Map<Character, Character> getCharacterEncodingMap() {
    return altFontEncoding4;
  }
}
